export interface LocationProps {
    classNames: Iterable<string>,
    id?: string
}

export function MergeClassNames(classNames: Iterable<string>, prop: Partial<LocationProps>): LocationProps {
    return {
        id: prop.id,
        classNames: Array.from(classNames).concat(Array.from(prop.classNames || []))
    };
}

export function ClassNameString(prop: LocationProps): string {
    return Array.from(prop.classNames).join(" ");
}